<template>
  <select 
    class="form-control" 
    v-model="model[schema.name]" 
    :multiple="schema.multiple"
    :disabled="schema.disabled" 
    :readonly="schema.readonly" 
    :required="schema.required" 
    :width="schema.width"
    :height="schema.height"
    :class="[`input-${schema.size||'md'}`, schema.className]"
  >
    <option :value="schema.defaultValue||''">{{schema.placeholder}}</option>
    <option v-for="option in schema.options" :value="option.value||option">{{option.label||option}}</option>
  </select>
</template>
<script>
import XBase from './XBase.vue'
export default {
  name: 'XSelect',
  extends: XBase
}
</script>
<style></style>